package com.mysoft.gfyx.marketdevelop.controller.common;

import com.mysoft.framework.rpc.annotation.PubAction;
import com.mysoft.framework.rpc.annotation.PubService;
import com.mysoft.framework.rpc.contants.RequestPrefix;
import com.mysoft.gfyx.marketdevelop.remoteService.RemoteProfitProvinceService;
import com.mysoft.gfyx.marketdevelop.remoteService.dto.CheckProfitRequestDto;
import io.swagger.annotations.ApiOperation;
import io.swagger.v3.oas.annotations.tags.Tag;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.RequestBody;
import org.springframework.web.bind.annotation.RequestMethod;

@PubService(value = "/profitDataApi", prefix = RequestPrefix.API)
@Tag(name = "权益相关-API")
public class ProfitDataApiController {

    @Autowired
    private RemoteProfitProvinceService remoteProfitProvinceService;

    @PubAction(value = "/checkProfitEffectByCode", method = RequestMethod.POST)
    @ApiOperation(value = "/getWxQrCode", notes = "通过产品code校验权益")
    public boolean checkProfitEffectByCode(@RequestBody CheckProfitRequestDto dto) {
        return remoteProfitProvinceService.checkProfitEffectByCode(dto);
    }

}
